<?php session_start (); if (isset($_SESSION['login']) && isset($_SESSION['mdp']) && $_SESSION['Autorisation'] == 3) {?>
<html>
<head>
<link rel="stylesheet" href="styleadmin.css" />
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" >
<title>sans titre 1</title>
</head>

<body>

	<div id="container">
		<div id="top">
			<?php include '../header.php'; ?>
		</div>
			
		<div id="leftnav">
			<?php include 'menu-administration.php'; ?>
		</div>
	
		<div id="content">
			<?php
			try
			{
			include '../include/Data.php';
			$NumArticle = $_POST['NumArticle'];
			$Titre = $_POST['Titre'];
			$DateArticle = $_POST['DateArticle'];
			$Contenu = $_POST['Contenu'];
			
			$r = "UPDATE article SET Titre='".$Titre."', DateArticle='".$DateArticle."',Contenu='".$Contenu."' WHERE NumArticle='".$NumArticle."';";
			$req = mysql_query($r,$connexion);	
			echo 'Article bien modifié !';
			mysql_close($connexion);
			}
			catch(Exception $e)
			{
			die('Erreur : '.$e->getMessage());
			}
			?>
		</div>
		
		<div id="footer">
		<?php include '../footer.php'; ?>
		</div>
 	
	</div>
</body>
</html>
<?php } else { header("Refresh: 0; URL=../index.php"); }?>